<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <title>注册页</title>
    <link rel="stylesheet" href="__PUBLIC__/layui/css/layui.css">
    <link rel="stylesheet" href="__PUBLIC__/static/css/style.css">
    <link rel="icon" href="__PUBLIC__/static/image/code.png">
</head>
<body>

<div class="login-main">
    <header class="layui-elip">找回密码</header>
    <form class="layui-form" method="post">
        <div class="layui-input-inline">
            <input type="text" name="user" required  lay-verify="required" placeholder="用户名" autocomplete="off" class="layui-input">
        </div>

        <div class="layui-input-inline">
            <input type="text" name="email" required  lay-verify="required|email" placeholder="邮箱" autocomplete="off" class="layui-input">
        </div>
            <div class="layui-input-inline">
                <input type="text" name="captcha" class="layui-input" lay-verify="code" placeholder="验证码" maxlength="4"  style="width:80px;float:left;"/><img src="{:url('verify')}" onclick="this.src='{:url('verify')}?'+Math.random()"  alt="">
            </div>

        <div class="layui-input-inline login-btn">
            <button type="submit" class="layui-btn">注册</button>
        </div>
        <hr/>
        <p><a href="{:url('index')}" class="fl">已有账号？立即登录</a><a href="{:url('resetpwd')}" class="fr">忘记密码？</a></p>
    </form>
</div>


<script src="__PUBLIC__/layui/layui.js"></script>
<script type="text/javascript">
    layui.use(['form'], function () {
        var form    = layui.form
            ,$      = layui.jquery;

        // you code ...
//添加验证规则  
    form.verify({     
  
        // password : function(value, item){  
        //     if(value.length < 6){  
        //         return "密码长度不能小于6位";  
        //     }  
        // },  
        // confirmpassword : function(value, item){  
        //     if(!new RegExp($("#oldPwd").val()).test(value)){  
        //         return "两次输入密码不一致，请重新输入！";  
        //     }  
        

    });
</script>
</body>
</html>